package com.dyj.common.enums;

public enum DyGoodLifeUrlPathEnum {
    /**
     * 通用接口->代运营->创建合作关系
     */
    CREATE_PARTNER_ORDER("createPartnerOrder", "/goodlife/v1/partner/order/create/"),

    /**
     * 通用接口->代运营->合作列表获取
     */
    QUERY_PARTNER_ORDER("queryPartnerOrder", "/goodlife/v1/partner/order/query/"),

    /**
     * 通用接口->代运营->合作详情查询
     */
    GET_PARTNER_ORDER("getPartnerOrder", "/goodlife/v1/partner/order/get/"),


    /**
     * 通用接口->代运营->创建/修改佣金
     */
    SAVE_COMMISSION("saveCommission", "/goodlife/v1/partner/product_commission/save/"),

    /**
     * 通用接口->代运营->佣金变更记录列表
     */
    QUERY_COMMISSION_RECORD("queryCommissionRecord", "/goodlife/v1/partner/commission_record/query/"),
    ;






    private String key;
    private String value;

    DyGoodLifeUrlPathEnum(String key, String value) {
        this.key = key;
        this.value = value;
    }

    public String getKey() {
        return key;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public void setKey(String key) {
        this.key = key;
    }

    public static String getValueByKey(String key) {
        for (DyGoodLifeUrlPathEnum e : DyGoodLifeUrlPathEnum.values()) {
            if (e.getKey().equals(key)) {
                return e.getValue();
            }
        }
        return null;
    }
}
